-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
BlockDraggable: Remove invalid aria-hidden attribute from button #64228
Conversation
f45140f
to
96da007
Compare
Size Change: -6 B (0%) Total Size: 1.77 MB
ℹ️ View Unchanged
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.
To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, @t-hamano!
This fixes the error produced by Chrome, and the button is still not focusable via the keyboard.
What?
This PR fixes the following browser console error that occurs when interacting with a block drag handle with the mouse:
Note: I saw this warning in Google Chrome 127.0.6533.89, and I don't understand why it's only happening now, since this code has been around for several years 🤷♂️
StrictMode
enabled in #61943 does not appear to be related to this issue.85f70ff16f733fb09c2fc65febc11ced.mp4
Why?
We should not apply
aria-hidden="true"
to focusable elements.How?
Delete
aria-hidden="true"
. SincetabIndex
is-1
, we should not be able to tab to the drag handle as before.Testing Instructions